<template>
   <el-popconfirm
        :confirm-button-text='confirmButtonText?confirmButtonText:"确认"'
        :cancel-button-text='cancelButtonText?cancelButtonText:"取消"'
        :title="title?title:'确认要删除吗'"
        @confirm='confirm'
        @cancel='cancel'
    >
        <el-button type="danger" slot="reference">{{value?value:'删除'}}</el-button>
    </el-popconfirm>
</template>

<script>
export default {
    props:['confirmButtonText','cancelButtonText','title','value'],
    methods:{
        confirm(){
            this.$emit('confirm')
        },
        cancel(){
            this.$emit('cancel')
        }
    }
}
</script>

<style>

</style>